/**
 * Created by ${PRODUCT_NAME}.
 * User: skyler
 * Date: 2/28/11
 * Time: 9:21 AM
 * To change this template use File | Settings | File Templates.
 */
package com.thoughtorigin.media.ui.controller {
import com.thoughtorigin.application.Disposable;

import com.thoughtorigin.media.MediaPlayer;

import com.thoughtorigin.media.MediaPlayerEvent;

import com.thoughtorigin.media.VolumeEvent;

import flash.events.EventDispatcher;

public class VolumeController extends EventDispatcher implements Disposable {

    private var _mediaPlayer: MediaPlayer;

    public function VolumeController(mediaPlayer: MediaPlayer) {
        init(mediaPlayer);
    }

    protected function init(mediaPlayer: MediaPlayer): void {
        _mediaPlayer = mediaPlayer;
        _mediaPlayer.addEventListener(VolumeEvent.VOLUME_CHANGE, onVolumeChange, false, 0, true);
    }

    protected function onVolumeChange(event:VolumeEvent):void {

    }

    protected function get mediaPlayer(): MediaPlayer {
        return _mediaPlayer
    }

    public function dispose(... args):void {
    }
}
}
